# Maintainer:
pkgname=py3-pebble
pkgver=5.0.6
pkgrel=0
pkgdesc="Multi threading and processing eye-candy"
url="https://github.com/noxdafox/pebble"
arch="noarch"
license="LGPL-3.0-or-later"
makedepends="
	py3-gpep517
	py3-setuptools
	py3-wheel
	"
checkdepends="
	py3-pytest-forked
	py3-pytest-xdist
	"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/noxdafox/pebble/archive/refs/tags/$pkgver.tar.gz"
builddir="$srcdir/pebble-$pkgver"

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	python3 -m venv --clear --without-pip --system-site-packages .testenv
	.testenv/bin/python3 -m installer .dist/*.whl
	.testenv/bin/python3 -m pytest -n auto --forked
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
a2227623becd64a73d2b2c1e26decbcc80117688cabe2a738d91633079d97d34e5ca773d4cdaf3a3dc59b425f06b3a61aaefdf3cfa2f98e3681b4f807e8f8c94  py3-pebble-5.0.6.tar.gz
"
